package demo.service.impl;

import demo.base.service.impl.BaseServiceImpl;
import demo.entity.UserDO;
import demo.mapper.UserMapper;
import demo.service.UserService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

/**
 * @author meilin.huang
 * @date 2022-03-09 8:48 PM
 */
@Service
public class UserServiceImpl extends BaseServiceImpl<UserMapper, Long, UserDO> implements UserService {

    @Transactional(rollbackFor = Exception.class, propagation = Propagation.NESTED)
    @Override
    public void crate(UserDO user) {
        insert(user);
    }
}
